package com.example.master.service.Impl;

import com.example.master.entity.vo.SubjectVo;
import com.example.master.mapper.*;
import com.example.master.service.*;
import com.example.master.utils.*;

import org.springframework.beans.factory.annotation.*;
import org.springframework.stereotype.*;

import java.util.*;

/**
 * @Author Mr.Yuan
 * @Date 2023/2/5 18:06
 * @PackageName:com.example.master.service.Impl
 * @ClassName: ServiceImpl
 * @Description: TODO
 * @Version 1.0
 */

@Service
public class SubjectServiceImpl implements SubjectServices {
    @Autowired
    private SubjectMapper subjectMapper;


    @Override
    public Result findAll() {
        Result result =null;
        List<SubjectVo> allservice = subjectMapper.findAll();
        if (allservice != null) {
            result = Result.success(allservice);
            return result;
        }
        result = Result.error("查询为空");
        return result;
    }
}
